import request from '@/utils/request'


/**
 * 主页信息api
 * @param {any} query
 * @return
 */
export function post(query:any){
    return request({
        url:'/admin/my/information',
        method:'get',
        params:query,
    });
}

/**
 * 主页信息详细查询api
 */
export function postinformation(id:number){
    return request({
        url:'/admin/my/post/home/'+id,
        method:'get',
    })
}

/**
 * 修改首页信息api
 */
export function editpost(data:any){
    return request({
        url:'/admin/my/edit/information',
        method:'put',
        data:data,
    })
}





/**
 * 帖子内容api
 * @param {any} query
 * @return
 */
export function postConent(query : any){
    return request({
        url:'/admin/my/post',
        method: 'get',
        params: query,
    });
}

/**
 * 帖子内容详细查询
 */
export function getpostContent(id:any){
    return request({
        url:'/admin/my/post/'+id,
        method:'get'
    })
}



/**
 * 修改帖子内容api
 */
export function updataPostCotent(data:any){
    return request({
       url:'/admin/my/revise/post',
       method:'put',
       data:data,
    })
}

/**
 * 删除帖子内容api
 */
export function delContent(id : any){
    return request({
        url:'/admin/my/delete/post/'+id,
        method:'delete',
    })
}
